Open
Conversation
la-lev
reviewed
Apr 27, 2024
| @then('Verify there are cells shown') | ||
| def verify_cells_shown(context): | ||
| cells = context.driver.find_elements(*VERIFY_CELLS_SHOWN) | ||
| assert len(cells) > 0, "No cells are shown on the page" |
Collaborator
There was a problem hiding this comment.
great work with find_elements 👍
features/environment.py
Outdated
|
|
||
| context.driver.maximize_window() | ||
| context.driver.implicitly_wait(4) | ||
| context.wait = Application |
Collaborator
There was a problem hiding this comment.
context.wait = WebDriverWait(context.driver, timeout=15)
| @given('Open Target main page') | ||
| def open_target(context): | ||
| context.driver.get('https://www.target.com/') | ||
| context.driver.get('https://www.target.') |
Collaborator
There was a problem hiding this comment.
https://www.target.com/, ".com" is missing
features/steps/main_page_steps.py
Outdated
| def verify_header_links(context, expected_amount): | ||
| expected_amount = int(expected_amount) | ||
| header_links = context.driver.find_elements(*HEADER_LINKS) | ||
| assert len(header_links) == expected_amount, f'Expected {expected_amount} links, but got {len(header_links)}' |
| actual_colors.append(selected_color) | ||
| print(actual_colors) | ||
|
|
||
| assert expected_colors == actual_colors, f'Expected {expected_colors} did not match actual {actual_colors}' No newline at end of file |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.